package com.mingqijia.gassafety.db.entity;

import com.baomidou.mybatisplus.annotation.TableName;
import com.baomidou.mybatisplus.annotation.IdType;
import java.util.Date;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableField;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 探测器上报数据表
 * </p>
 *
 * @author guoliang.lao
 * @since 2023-10-12
 */
@Data
@EqualsAndHashCode(callSuper = true)
@TableName("t_record_detector_history")
@ApiModel(value="RecordDetectorHistory对象", description="探测器上报数据表")
public class RecordDetectorHistory extends BaseEntity {

    private static final long serialVersionUID=1L;

    @ApiModelProperty(value = "主键")
    @TableId(value = "id", type = IdType.AUTO)
    private Long id;

    @ApiModelProperty(value = "来源主键id")
    @TableField("origin_id")
    private Long originId;

    @ApiModelProperty(value = "控制器上报数据history表主键")
    @TableField("record_id")
    private Long recordId;

    @ApiModelProperty(value = "控制器上报数据表主键")
    @TableField("origin_record_id")
    private Long originRecordId;

    @ApiModelProperty(value = "报警器设备表主键")
    @TableField("device_id")
    private String deviceId;

    @ApiModelProperty(value = "探测器编号")
    @TableField("sub_id")
    private Integer subId;

    @ApiModelProperty(value = "客户编号")
    @TableField("consumer_id")
    private Integer consumerId;

    @ApiModelProperty(value = "探测气体类型 T-甲烷;M-CO;Y-丙烷;Q-氢气")
    @TableField("gas_type")
    private String gasType;

    @ApiModelProperty(value = "探测器状态 0-正常,32-寿命到期,33-探测器故障,34-传感器故障,35-电磁干扰")
    @TableField("detector_status")
    private Integer detectorStatus;

    @ApiModelProperty(value = "报警类型 0-报警恢复 1-低限报警 2-高限报警 3-变化监测 5-报警")
    @TableField("alert_type")
    private Integer alertType;

    @ApiModelProperty(value = "浓度值")
    @TableField("concentration")
    private Integer concentration;

    @ApiModelProperty(value = "温度")
    @TableField("temperature")
    private Integer temperature;

    @ApiModelProperty(value = "湿度")
    @TableField("humidity")
    private Integer humidity;

    @ApiModelProperty(value = "上报时间")
    @TableField("record_at")
    private Date recordAt;

    @ApiModelProperty(value = "企业编号")
    @TableField("sp_id")
    private String spId;


}
